import Vue from 'vue'
import Router from 'vue-router'

Vue.use(Router);

import Add from "../components/Add.vue";
import Collect from "../components/Collect.vue";
import Detail from "../components/Detail.vue";
import Home from "../components/Home.vue";
import List from "../components/List.vue";




export default new Router({
    routes: [{
        path: "/home",
        component: Home,
        meta: { keepAlive: true }
    }, {
        path: "/add",
        component: Add
    }, {
        path: "/collect",
        component: Collect
    }, {
        path: "/list",
        component: List
    }, {
        name: "detail",
        path: "/detail/:bid",
        component: Detail
    }, {
        path: "*",
        redirect: "/home"
    }]
})